﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace AirlineProject.Models
{
    public class FlightModels
    {
        private DataClassesProjectAirlineDataContext dc = new DataClassesProjectAirlineDataContext();
        public List<Flight> ListFlight()
        {
            return this.dc.Flights.ToList();
        }
        public Flight InfoFlight(int id)
        {
            return this.dc.Flights.Single(f=>f.flight_id == id);
        }
        public Flight seatnumflight(int id)
        {
            return this.dc.Flights.Single(f => f.flight_id == id);
        }
    }
}